class Person():
    def __init__(self,name,sex,age):
        
        self.name=name
        self.sex=sex
        self.age=age
    def run(self):
        print(self.name.title()+" is running")
    def eat(self):
        print(self.name.title()+" is eating")
    def sleep(self):
        print(self.name.title()+" is sleeping")

class Student(Person):
    def __init__(self,name,sex,age,score):
        super().__init__(name,sex,age)
        self.score=score
    def study(self):
        print(self.name.title()+" is studying")

class Teacher(Person):
    def __init__(self,name,sex,age,subject):
        super().__init__(name,sex,age)
        self.subject=subject
    def teach(self):
        print(self.name.title()+" is teaching")
              

f1_Person=Person("Carry","Male",20)
print(f1_Person.name)
print(f1_Person.sex)
print(f1_Person.age)
f1_Person.run()

print()
f1_Teacher=Teacher("Mary","Female",30,"Python")
print(f1_Teacher.name)
print(f1_Teacher.sex)
print(f1_Teacher.age)
print(f1_Teacher.subject)
f1_Teacher.teach()